package com.example.lin.day9_27.utils;

import com.example.lin.day9_27.pojo.ResultData;
import com.example.lin.day9_27.pojo.User;

import io.reactivex.Observable;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.POST;

public interface ApiRequestService {

    //http://192.168.3.100:8080/home/register
    @POST("register")
    @FormUrlEncoded
//表示需要提交 Form表单数据(POST键值对)
    Observable<ResultData> register(@Field("userName") String userName, @Field("psw") String psw);
  //http://192.168.3.100:8080/home/register


    @POST("login")
    @FormUrlEncoded
//表示需要提交 Form表单数据(POST键值对)
    Observable<ResultData<User>> login(@Field("userName") String userName, @Field("psw") String psw);


}
